import React from 'react'
import { useParams,useLocation } from 'react-router-dom'
export default function Msg() {
    // const name = useParams().name
    const {state} = useLocation()
    return (
        <div>
        <h1>我是msg</h1>
        <span>接受到的姓名{state.name}</span>
        </div>
    )
}